{// 引入标签库 }
<tagLib name="html" />
<include file="Public:header" />
<load href='__TMPL__Common/js/vote_ask.js' />
<div class="main">
<div class="main_title">[{$vote.name}] {%VOTE_ASK} <a href="{:u("Vote/index")}" class="back_list">{%BACK_LIST}</a></div>
<div class="blank5"></div>
<form name="edit" action="__APP__" method="post" enctype="multipart/form-data">
<table class="form" cellpadding=0 cellspacing=0 id="ask_form">
	<tr>
		<td colspan=5 class="topTd"></td>
	</tr>
	<tr >
		<th>{%NAME}</th>
		<th>{%SORT}</th>
		<th>{%VOTE_TYPE}</th>
		<th>{%VOTE_VAL_SCOPE}</th>
		<th>操作 [<a href='javascript:void(0);' onclick="add_ask_row();">+</a>]</th>
	</tr>
	<foreach name="vote_ask" item="ask">
		<tr>
		<td style="text-align:center;"><input type="text" class="textbox require" name="name[]" value="{$ask.name}" /></td>
		<td style="text-align:center;"><input type="text" class="textbox " name="sort[]" value="{$ask.sort}" /></td>		
		<td style="text-align:center;">
			{%SINGLE_SELECT}:<input type="radio" name="type[{$key}][]" value='1' <if condition="$ask['type'] eq 1 or $ask['type'] eq 4">checked="checked"</if> />
			{%MULITY_SELECT}:<input type="radio" name="type[{$key}][]" value='2' <if condition="$ask['type'] eq 2 or $ask['type'] eq 5">checked="checked"</if> />
			{%DEFINE_SELECT}:<input type="checkbox"  name="type[{$key}][]" value='3' <if condition="$ask['type'] eq 3 or $ask['type'] eq 4 or $ask['type'] eq 5">checked="checked"</if> />
		</td>		
		<td style="text-align:center;">
			<textarea class="textarea" name="val_scope[]">{$ask.val_scope}</textarea>
		</td>
		<td style="text-align:center;">
			[<a href='javascript:void(0);' onclick="remove_ask_row(this);">-</a>]
		</td>
		</tr>
	</foreach>
	<tr id='footer_row'>
		<td colspan=5 class="bottomTd"></td>
	</tr>
</table>
<div class="blank5"></div>
<table class="form" cellpadding=0 cellspacing=0>
	<tr>
		<td colspan=2 class="topTd"></td>
	</tr>	
	<tr>
		<td class="item_title"></td>
		<td class="item_input">
			<!--隐藏元素-->
			<input type="hidden" name="vote_id" value="{$vote.id}" />
			<input type="hidden" name="{:conf("VAR_MODULE")}" value="Vote" />
			<input type="hidden" name="{:conf("VAR_ACTION")}" value="do_vote_ask" />
			<!--隐藏元素-->
			<input type="submit" class="button" value="{%EDIT}" />
			<input type="reset" class="button" value="{%RESET}" />
		</td>
	</tr>
	<tr>
		<td colspan=2 class="bottomTd"></td>
	</tr>
</table>	 
</form>
</div>
<include file="Public:footer" />